import request from '@/utils/request'

// 查询出库列表列表
export function listOutbound(query) {
  return request({
    url: '/wm/outbound/list',
    method: 'get',
    params: query
  })
}

// 查询出库列表详细
export function getOutbound(outboundId) {
  return request({
    url: '/wm/outbound/' + outboundId,
    method: 'get'
  })
}

// 新增出库列表
export function addOutbound(data) {
  return request({
    url: '/wm/outbound',
    method: 'post',
    data: data
  })
}

// 同步出库列表
export function syncWmOutbound() {
  return request({
    url: '/wm/outbound/sync',
    method: 'get'
  })
}

// 修改出库列表
export function updateOutbound(data) {
  return request({
    url: '/wm/outbound',
    method: 'put',
    data: data
  })
}

// 删除出库列表
export function delOutbound(serialNumber) {
  return request({
    url: '/wm/outbound/' + serialNumber,
    method: 'delete'
  })
}


export function getIssueList(query) {
  console.log("getIssueList>>>"+query)
  return request({
    url: '/wm/outbound/issueList',
    method: 'get',
    params: query
  });
}

export function getPurcList(query) {
  return request({
    url: '/wm/outbound/purcList',
    method: 'get',
    params: query
  });
}
